<!doctype html>
<html lang="en">
  <head>
    <!-- Required meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">

    <!-- Bootstrap CSS -->
<link rel="stylesheet" href="/static/polls/js/bootstrap.min.css">

    <!-- Optional JavaScript -->

    <title>国烨运维管理系统</title>
          <style type="text/css">
        form.big
            {
                width: 40%
            }
        td div {
             width:160px;
    }
        .dropbtn {
            background-color:#3A3838;
            color: white;
            padding: 3px;
            font-size: 20px;
            border: none;
            cursor: pointer;
             }

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #3A3838;
    min-width: 100px;
    box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
}

.dropdown-content a {
    color: black;
    padding: 6px 6px;
    text-decoration: none;
    display: block;
}

.dropdown-content a:hover {background-color: green}

.dropbtn a:hover {background-color: green}

.dropdown:hover .dropdown-content {
    display: block;
}

.dropdown:hover .dropbtn {
    background-color: #3A3838;
}

    </style>
  </head>
  <body>


  <div class="container-fluid" >
  <div class="row">

        <nav class="navbar navbar-expand-lg navbar-dark  bg-dark" style="width: 100% ">
    <div align="center">

    <a class="navbar-brand  btn-outline-danger"  href="#" id="bt_deploy_bk">后端</a>
    <a class="navbar-brand  btn-outline-primary" href="#" id="bt_deploy_ft" >前端</a>
    <a class="navbar-brand  btn-outline-success" href="#" id="deploy_logs">日志</a>
    <a class="navbar-brand  btn-outline-warning" href="#" id="jenkins">Jenkins</a>


    </div>
    <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarText" aria-controls="navbarText" aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span>
    </button>
    <div class="collapse navbar-collapse" id="navbarText">
        <ul class="navbar-nav mr-auto">
            <li class="nav-item ">
             <div style="width: 100px">     <a class="nav-link btn-outline-info"   href="#">数据库更新 <span class="sr-only">(current)</span></a> </div>
            </li>

            <li class="nav-item">
             <div style="width: 100px">     <a class="nav-link btn-outline-info" href="#">环境监控</a> </div>
            </li>

        </ul>
        <span class="navbar-text">
            <div style="width: 100px">
        <a class="navbar-brand btn-outline-info"  href="/polls/logouts">注销</a> </div>
    </span>
    </div>
</nav>




</div>

 <div class="row" id="details" >



</div>

</div>
</center>





 <script src="/static/polls/js/2.1.4/jquery.min.js"></script>
<script src="/static/polls/js/popper.min.js"></script>
<script src="/static/polls/js/bootstrap.min.js" ></script>







  <script>

        $('#bt_deploy_bk').click(function () {
//            $.get("/polls/deploy_backend/", function (response) {
//                $('#details').html(response);
//            })
            $.ajax({
              type: "get",      //data 传送数据类型。post 传递
              url: "/polls/deploy_backend/",  // yii 控制器/方法
              cache: false,
                success: function (response) {
                $('#details').html(response);
              }
            })
        });



        $('#jenkins').click(function () {
            $.ajax({
              type: "get",      //data 传送数据类型。post 传递
              url: "/polls/jenkins/",  // yii 控制器/方法
              cache: false,
                success: function (response) {
                $('#details').html(response);
              }
            })
        });


        $('#bt_deploy_ft').click(function () {
//            $.get("/polls/deploy_frontend/", function (response) {
//                $('#details').html(response);
//            })
            $.ajax({
              type: "get",      //data 传送数据类型。post 传递
              url: "/polls/deploy_frontend/",  // yii 控制器/方法
              cache: false,
                success: function (response) {
                $('#details').html(response);
              }
            })
        });

        $('#deploy_logs').click(function () {
//            $.get("/static/polls/test.txt", function (response) {
//                $('#details').html(response);
//            })
            $.ajax({
              type: "get",      //data 传送数据类型。post 传递
              url: "/polls/deploy_logs",  // yii 控制器/方法
              cache: false,
                success: function (response) {
                $('#details').html(response);
              }
            })
        });

              $('#locked_user').click(function () {
//            $.get("/static/polls/test.txt", function (response) {
//                $('#details').html(response);
//            })
            $.ajax({
              type: "get",      //data 传送数据类型。post 传递
              url: "/polls/locked_user",  // yii 控制器/方法
              cache: false,
                success: function (response) {
                $('#details').html(response);
              }
            })
        });

</script>



  </body>
</html>